home *** CD-ROM | disk | FTP | other *** search
- property pSprite, spriteNum, pbar, pLine, pGo, ppos, ptext, ptotal
-
- on getPropertyDescriptionList me
- return [#pbar: [#comment: " ", #format: #integer, #default: 0], #ptext: [#comment: " ", #format: #string, #default: "ass"]]
- end
-
- on beginSprite me
- pSprite = sprite(spriteNum)
- pLine = sprite(pbar)
- pSprite.loc = pLine.pTop
- ppos = 0
- pGo = 0
- if spriteNum = 23 then
- ptotal = 527
- else
- ptotal = 583
- end if
- end
-
- on mouseDown me
- pGo = 1
- end
-
- on mouseUp me
- pGo = 0
- end
-
- on mouseUpOutSide me
- mouseUp(me)
- end
-
- on positio me
- barl = pLine.pBottom - pLine.pTop
- percent = (pSprite.locV - pLine.pTop) * 100.0 / barl
- total = ptotal
- newscroll = percent * total / 100.0
- member(ptext).scrollTop = newscroll
- end
-
- on slide me
- ww = ptotal
- ss = member(ptext).scrollTop.float * 100.0 / ww.float
- bart = pLine.pBottom - pLine.pTop
- asd = bart * ss / 100.0
- pSprite.locV = pLine.pTop + asd
- end
-
- on exitFrame me
- if pGo then
- pSprite.locH = pLine.locH
- pSprite.locV = the mouseV
- if pSprite.locV < pLine.pTop then
- pSprite.locV = pLine.pTop
- else
- if pSprite.locV > pLine.pBottom then
- pSprite.locV = pLine.pBottom
- end if
- end if
- barl = pLine.pBottom - pLine.pTop
- percent = (pSprite.locV - pLine.pTop) * 100.0 / barl
- total = ptotal
- newscroll = percent * total / 100.0
- member(ptext).scrollTop = newscroll
- end if
- end
-